<template>
	<view>
		<custom title="通用" mode="2" fixed="fixed"> </custom>
		

		

		<view class="flex">
			<view class="flex-content">
			
				<cell-list class="mt-20">
					<cell title="字体大小" @click="toPage('/pages/setting/fontsize')">
						<view slot="right" class="color-999999 fs-28"></view>
					</cell>
				</cell-list>
			</view>
		</view>

		<toast ref="toast"></toast>
		
	</view>
</template>

<script>
let envinfo = require("../../siteinfo.js");
export default {
	data() {
		return {
			envinfo: envinfo,
		};
	},
	methods: {
		logout() {
			this.$refs.toast.open({
				desc: "确定注销账号？",
				left: "我再想想",
				right: "退出",
				success: () => {
					this.less(() => {
						this.request({
							url: "/login/loginOut",
							method: "POST",
						}).then((res) => {
							// uni.$emit('logout');
							this.showToast('注销成功，等待后台审核');
							this.vuexSet("user_info", {}, true);
							uni.setStorageSync("ACCESS_TOKEN", "");
							uni.redirectTo({
								url: "/pages/login/login",
							});

							if (getApp().globalData.CHAT && getApp().globalData.CHAT.CLOSE) {
								getApp().globalData.CHAT.CLOSE();
							}
						});
					});
				},
			});
			uni.setStorage({
				key: "openid",
				data: "",
			});
		},
		choose_image() {
			uni.chooseImage({
				sourceType:['album'],
				count: 1,
				success: (res) => {
					let { tempFilePaths = [] } = res;
					console.log("res", res);
					tempFilePaths.forEach((val) => {
						// #ifdef APP-PLUS
						uni.compressImage({
							src: val,
							width: "200",
							success: (img) => {
								this.upload_image(img.tempFilePath);
								console.log("img.tempFilePath", img.tempFilePath);
							},
							fail: (err) => {
								console.log("err", err);
							},
						});
						// #endif

						// #ifdef H5
						this.upload_image(val);
						// #endif
					});
				},
			});
		},
	},
};
</script>

<style>
page {
	background-color: #f0f2f5;
}

.item-list-box {
	border-bottom: 2rpx solid #eeeeee;
	color: #323232;
	font-size: 28rpx;
	display: flex;
	align-items: center;
	background-color: #fff;
	padding: 30rpx 30rpx 30rpx 40rpx;
	line-height: 30rpx;
}

.setting-item {
	height: 112rpx;
	background-color: #ffffff;
	padding-right: 30rpx;
	color: #333 !important;
}

.setting-item>view {
	/* color: rgba(255, 255, 255, 1); */
}

.setting-item+.setting-item {
	/* border-top: 0.5px solid #D8D8D8; */
	border-top: 0.5px solid #eeeeee;
}

.abcd {
	height: 108rpx;
	background: #ffffff;

	color: #333;
}

.gray {
	color: #d4d5d7;
}
</style>
